\documentclass{ctexart}

\usepackage{ctex}
\usepackage{tikz}
\usetikzlibrary{calc,positioning,shapes.geometric}
\usepackage{url}
\usepackage{graphicx}
\usepackage{float}
\usepackage{xcolor}
\usepackage{color}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{amssymb}
\usepackage{mathrsfs}
\usepackage{caption}
\usepackage{subfigure}
\usepackage{framed}
\usepackage{booktabs}
\usepackage{makecell}
\usepackage{geometry}
\usepackage{wrapfig}
\usepackage{abstract}
\usepackage{algorithmicx}
\usepackage[ruled]{algorithm}
\usepackage{algpseudocode}
\usepackage{setspace}
\usepackage{bm}
\usepackage{cite}
\usepackage{array}
\usepackage{textcomp}
\usepackage{listings}

\usepackage{geometry}
\geometry{right=2.5cm,left=2.5cm}

\newtheorem{theorem}{定理}

\pagenumbering{arabic}

\begin{document}
\begin{sloppypar}
\title{\vspace{-3cm} \textbf{Homework 3 of Numerical Analysis}}
\author{刘陈若\;$3200104872$\\信息与计算科学2001}
\date{}

\maketitle

\section*{Theoretical questions}
\subsection*{Problem \uppercase\expandafter{\romannumeral1}}
\begin{proof}[\textbf{Solution.}]
Since $s\in \mathbb{S}^2_3$ and $s(0) = 0$, the constraints of $p(x)$ are
\begin{equation}
    p(0)=0, \quad p(1) = 1, \quad p'(1) = -3(2-1)^2=-3, \quad p^{''}(1) = 6(2-1) = 6.
\end{equation}
Suppose $p(x) = a_0 + a_1x+a_2x^2 + a_3x^3$, then we have
\begin{equation}
\begin{aligned}
    0 &= a_0, \\
    1 &= a_0 + a_1 + a_2 + a_3, \\
    -3 &= a_1 + 2a_2 + 3a_3, \\
    6 &= 2a_2 + 6a_3.
\end{aligned}      
\end{equation}
from which we know $p(x) = 12x-18x^2+7x^3$, $s^{''}(0)=p^{''}(0) = -36 \neq 0$. Therefore, $s(x)$ is not a natural cubic spline.
\end{proof}

\subsection*{Problem \uppercase\expandafter{\romannumeral2}}
\subsubsection*{(a)}
\begin{proof}[\textbf{Solution.}]
 From \textbf{Theorem 3.14}, $ \mathbb{S}^1_2(x_1,\dots, x_n)$ is a linear space with dimension $2+n-1 = n+1$. As $f_i = f(x_i)$ only give $n$ conditions, another one condition is needed for a unique element in the space.
\end{proof}
\subsubsection*{(b)}
\begin{proof}[\textbf{Solution.}]
Since each $p_i$ has constraints $p_i(x_i) = f_i$, $p_i(x_{i+1}) = f_{i+1}$ and $p'(x_i) = m_i$, the divided difference table for Hermite interpolation is
\begin{table}[H]
\renewcommand{\arraystretch}{1.2}
 \centering
 \setlength{\tabcolsep}{0.3cm}{
\begin{tabular}{c|ccc}
    $x_i$ & $f_i$  \\
    $x_i$ & $f_i$ & $m_i$ \\
    $x_{i+1}$ & $f_{i+1}$ & $K_i$ & $\frac{K_i-m_i}{x_{i+1}-x_i}$ \\
\end{tabular}}
\end{table}
where $K_i = f[x_i,x_{i+1}]$ is a constant under the condition. Thus $p_i(i = 1,2\dots,n-1)$ can be determined as
\begin{equation}
    p_i = f_i + m_i(x-x_i) + \frac{K_i-m_i}{x_{i+1}-x_i}(x-x_i)^2.
\end{equation}
\end{proof}
\subsubsection*{(c)}
\begin{proof}[\textbf{Solution.}]
 We know that $p'_i(x_{i+1}) = p'_{i+1}(x_{i+1}) = m_{i+1}$ must be held for $i = 1,2,\dots,n-2$. Then we have $n-2$ equations using (b)
 \begin{equation}
     m_i +2(K_i - m_i) = m_{i + 1} \quad \Longrightarrow \quad m_i + m_{i+1} = 2K_i = 2\frac{f_{i+1}-f_i}{x_{i+1}-x_i} .
 \end{equation}
 Now $m_1 = f'(a)$ is given, then $m_2,m_3,\dots,m_{n-1}$ can be computed by recursion $m_{i+1} = 2K_i - m_i\,(m_1 = f'(a))$ or solving the linear equations. The uniqueness of $m_i$ can also be attained from Cramer's rule since the determinant of the equations' coefficient matrix is 1.
\end{proof}

\subsection*{Problem \uppercase\expandafter{\romannumeral3}}
\begin{proof}[\textbf{Solution.}]
Since $s\in \mathbb{S}^2_3$ and is natural cubic spline, the constraints of $s_2(x)$ are
\begin{equation}
    s_2(0)=s_1(0) = 1+c, \quad s'_2(0) = s'_1(0)=3c, \quad s^{''}_2(0) = s^{''}_2(0) = 6c, \quad s^{''}_2(1) = 0.
\end{equation}
Suppose $s_2(x) = a_0 + a_1x+a_2x^2 + a_3x^3$, then we have
\begin{equation}
\begin{aligned}
    &1+c = a_0, \\
    &3c = a_1, \\
    &6c = 2a_2, \\
    &0 = 2a_2 + 6a_3.
\end{aligned}      
\end{equation}
from which we know $s_2(x) = 1+c + 3cx + 3cx^2 -cx^3$.

Furthermore, if $s(1) = -1$, then
\begin{equation}
    s_2(1) =  6c+1=-1 \quad \Longrightarrow \quad c=-\frac{1}{3}.
\end{equation}

\end{proof}

\subsection*{Problem \uppercase\expandafter{\romannumeral4}}
\subsubsection*{(a)}
\begin{proof}[\textbf{Solution.}]
Suppose the natural cubic spline interpolant satisfies
\begin{align*}
\begin{split}
s(x)= \left \{
\begin{array}{ll}
    s_1(x),                    & x \in [-1,0)\\
    s_2(x),                    & x \in [0,1]
\end{array}
\right.
\end{split}
\end{align*}
Using the same denotation in \textbf{Lemma 3.4}, we have
\begin{equation}
    s_1(x) = f_1 + s'_1(-1)(x+1)+\frac{M_1}{2}(x+1)^2+\frac{s^{'''}_1(-1)}{6}(x+1)^3.
\end{equation}
For $f_1$, obviously $f_1=f(-1) = 0$. For $M_1$, it's zero since $s$ is a natural cubic spline. We also know that $f(0) = 1$, $f(1) = 0$, $f[-1,0] = 1$, $f[0,1] = -1$, $f[-1,0,1] = -1$. Similar to \textbf{Problem \uppercase\expandafter{\romannumeral3}},
\begin{equation}
    2M_2 = \frac{1}{2}M_1 + 2M_2 + \frac{1}{2}M_3 = 6f[-1,0,1] = -6.
\end{equation}
thus $M_2=-3$. Therefore, for $s'_1(-1)$, according to (3.10) in textbook, we have
\begin{equation}
    s'_1(-1) = f[-1,0]-\frac{1}{6}(M_2 + 2M_1)(0+1) = \frac{3}{2}.
\end{equation}
For $s^{'''}_1(-1)$, according to (3.9) in textbook, we have
\begin{equation}
    s^{'''}_1(-1) = \frac{M_2-M_1}{0+1} = -3.
\end{equation}
Hence, $s_1(x) = \frac{3}{2}(x+1) -\frac{1}{2}(x+1)^3$

The method to calculate $s_2(x)$ is almost the same,
\begin{equation}
    s_2(x) = f_2 + s'_2(0)x+\frac{M_2}{2}x^2+\frac{s^{'''}_2(0)}{6}x^3.
\end{equation}
where $f_2 = f(0) = 1$, $M_2 = -3$. For $s'_2(0)$ and $s^{'''}_2(0)$, 
\begin{equation}
    s'_2(0) = f[0,1]-\frac{1}{6}(M_3 + 2M_2)(1-0) = 0, \quad s^{'''}_2(0) = \frac{M_3-M_2}{1-0} = 3.
\end{equation}
Hence, $s_2(x) = 1 - \frac{3}{2}x^2 + \frac{1}{2}x^3$. For a conclusion, 
\begin{align*}
\begin{split}
s(x)= \left \{
\begin{array}{ll}
    \frac{3}{2}(x+1) -\frac{1}{2}(x+1)^3,                    & x \in [-1,0)\\
    1 - \frac{3}{2}x^2 + \frac{1}{2}x^3.                    & x \in [0,1]
\end{array}
\right.
\end{split}
\end{align*}
\end{proof}
\subsubsection*{(b)}
\begin{proof}[\textbf{Solution.}]
It's obvious that in case (i), $g(x) = -x^2 + 1$, so
\begin{equation}
\begin{aligned}
    \int_{-1}^{1} [s^{''}(x)]^2\, dx &= \int_{-1}^{0} [-3(x+1)]^2\, dx + \int_{0}^{1} (-3+3x)^2\, dx = 6, \\
    \int_{-1}^{1} [g^{''}(x)]^2\, dx &= \int_{-1}^{1} 4\, dx =8 > 6,\\
    \int_{-1}^{1} [f^{''}(x)]^2\, dx  &=  \int_{-1}^{1} [-\frac{\pi^2}{4}\cos(\frac{\pi}{2}x)]^2\, dx  = \frac{\pi^4}{16} \approx 6.088 > 6.
\end{aligned}      
\end{equation}
The results verify Minimum bending energy of natural cubic spline.
\end{proof}

\subsection*{Problem \uppercase\expandafter{\romannumeral5}}
\subsubsection*{(a)}
\begin{proof}[\textbf{Solution.}]
From \textbf{Definition 3.23} and \textbf{Example 3.24}, the quadratic B-spline satisfies
\begin{equation}
    B^2_i(x) = \frac{x-t_{i-1}}{t_{i+1}-t_{i-1}}\hat{B}_i(x) + \frac{t_{i+2}-x}{t_{i+2}-t_{i}}\hat{B}_{i+1}(x).
\end{equation}
After applying \textbf{Definition 3.21}, we finally attain
\begin{align*}
\begin{split}
B^2_i(x)= \left \{
\begin{array}{ll}
     \frac{x-t_{i-1}}{t_{i+1}-t_{i-1}}\hat{B}_i(x)=\frac{(x-t_{i-1})^2}{(t_{i+1}-t_{i-1})(t_{i}-t_{i-1})},                    & x \in (t_{i-1},t_i]\\
    \frac{x-t_{i-1}}{t_{i+1}-t_{i-1}}\hat{B}_i(x) + \frac{t_{i+2}-x}{t_{i+2}-t_{i}}\hat{B}_{i+1}(x)= \frac{(x-t_{i-1})(t_{i+1}-x)}{(t_{i+1}-t_{i-1})(t_{i+1}-t_{i})} +\frac{(t_{i+2}-x)(x-t_i)}{(t_{i+2}-t_{i})(t_{i+1}-t_{i})},                   & x \in (t_{i},t_{i+1}]\\
    \frac{t_{i+2}-x}{t_{i+2}-t_{i}}\hat{B}_{i+1}(x) = \frac{(t_{i+2}-x)^2}{(t_{i+2}-t_{i})(t_{i+2}-t_{i+1})}, & x \in (t_{i+1},t_{i+2}]\\
    0 &otherwise
\end{array}
\right.
\end{split}
\end{align*}
\end{proof}
\subsubsection*{(b)}
\begin{proof}[\textbf{Solution.}]
According to what have been derived in (a), the left and right derivatives of $B^2_i(x)$ at $t_i$ and $t_{i+1}$ are
\begin{equation}
\begin{aligned}
    \lim_{x \rightarrow t^-_i}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)  &= \frac{2(t_i-t_{i-1})}{(t_{i+1}-t_{i-1})(t_{i}-t_{i-1})} = \frac{2}{t_{i+1}-t_{i-1}}, \\
    \lim_{x \rightarrow t^+_i}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)  &= \frac{1}{t_{i+1}-t_{i-1}}+\frac{t_{i-1}-t_{i}}{(t_{i+1}-t_{i-1})(t_{i+1}-t_{i})}+\frac{1}{t_{i+1}-t_{i}} = \frac{2}{t_{i+1}-t_{i-1}},\\
    \lim_{x \rightarrow t^-_{i+1}}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)  &= \frac{1}{t_{i}-t_{i+1}}+\frac{t_{i+2}-t_{i+1}}{(t_{i+2}-t_{i})(t_{i+1}-t_{i})}+\frac{1}{t_{i}-t_{i+2}} = \frac{2}{t_{i}-t_{i+2}},\\
    \lim_{x \rightarrow t^+_{i+1}}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)  &= \frac{-2(t_{i+2}-t_{i+1})}{(t_{i+2}-t_{i})(t_{i+2}-t_{i+1})} = \frac{2}{t_{i}-t_{i+2}}.
\end{aligned}      
\end{equation}
Therefore, $\lim_{x \rightarrow t^-_i}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)=\lim_{x \rightarrow t^+_i}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)$, $\lim_{x \rightarrow t^-_{i+1}}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)=\lim_{x \rightarrow t^+_{i+1}}\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)$, thus verifying the continuity of $\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)$ at $t_i$ and $t_{i+1}$. 
\end{proof}
\subsubsection*{(c)}
\begin{proof}[\textbf{Solution.}]
From (a) we know
\begin{align*}
\begin{split}
\frac{\mathrm{d}}{\mathrm{d} x}B^2_i(x)= \left \{
\begin{array}{ll}
     \frac{2(x-t_{i-1})}{(t_{i+1}-t_{i-1})(t_{i}-t_{i-1})},                    & x \in (t_{i-1},t_i]\\
     \frac{t_{i-1}+t_{i+1}-2x}{(t_{i+1}-t_{i-1})(t_{i+1}-t_{i})} +\frac{t_i+t_{i+2}-2x}{(t_{i+2}-t_{i})(t_{i+1}-t_{i})},                   & x \in (t_{i},t_{i+1}]\\
    \frac{2(x-t_{i+2})}{(t_{i+2}-t_{i})(t_{i+2}-t_{i+1})}, & x \in (t_{i+1},t_{i+2}]\\
    0. &otherwise
\end{array}
\right.
\end{split}
\end{align*}
Therefore, if $x^*\in (t_{i-1},t_i]$, then $x^*-t_{i-1} = 0$, and the solution is $x^* = t_{i-1}$, which is out of the interval's range.

If $x^*\in (t_{i},t_{i+1}]$, then solving the equation we have
\begin{equation}
    x^* = \frac{t_{i+1}t_{i+2}-t_{i-1}t_i}{(t_{i+1}+t_{i+2})-(t_{i-1}+t_i)}.
\end{equation}
The following proof is to confirm $x^*\in (t_{i},t_{i+1}]$. For the inequality $t_i<x^*$, it suffices to prove $t_{i+1}t_{i+2}-t_{i-1}t_i > t_i[(t_{i+1}+t_{i+2})-(t_{i-1}+t_i)]$. After simplifying the inequality, we get $t_i(t_{i+1}-t_i)<t_{i+2}(t_{i+1}-t_i)$, which is obviously correct since $t_i < t_{i+2}$. The other inequality $t_{i+1}>x^*$ can be attained similarly. Hence we complete the proof.
\end{proof}
\subsubsection*{(d)}
\begin{proof}[\textbf{Solution.}]
Explicit expression in (a) shows that obviously $B^2_i(x) \geq 0$ because all terms of the expression in the support of $B^2_i(x)$ is greater than zero, and $0$ can be obtained at every point outside the support. Therefore, we now only need to show that $B^2_i(x) < 1$.

Consider the interval of support, in which the maximum of $B^2_i(x)$ can be obtained. Since we have shown that the derivative of $B^2_i(x)$ is continuous and the function has value of 0 at the support's endpoints, $B^2_i(x)$ must reach its maximum at $x^*$, where its derivative vanishes. 

That is to say,
\begin{equation}
\begin{aligned}
    B^2_i(x) \leq B^2_i(x^*) &= \frac{(t_{i+2}-t_{i-1})(t_{i+1}-t_{i-1})}{[(t_{i+1}+t_{i+2})-(t_{i-1}+t_i)]^2} + \frac{(t_{i+2}-t_{i-1})(t_{i+2}-t_{i})}{[(t_{i+1}+t_{i+2})-(t_{i-1}+t_i)]^2} \\
    &= \frac{t_{i+2}-t_{i-1}}{(t_{i+2}-t_{i-1})+(t_{i+1}-t_i)} \\
    & < 1.
\end{aligned}      
\end{equation}
Hence we have finished the proof.
\end{proof}
\subsubsection*{(e)}
\begin{proof}[\textbf{Solution.}]
If $t_i = i$, then
\begin{align*}
\begin{split}
B^2_i(x)= \left \{
\begin{array}{ll}
     =\frac{(x-i+1)^2}{2},                    & x \in (i-1,i]\\
    = \frac{(x-i+1)(i+1-x)}{2} +\frac{(i+2-x)(x-i)}{2},                   & x \in (i,i+1]\\
    = \frac{(i+2-x)^2}{2}, & x \in (i+1,i+2]\\
    0 &otherwise
\end{array}
\right.
\end{split}
\end{align*}
The function image plotted by PYTHON is shown below.
\begin{figure}[H]
\centering
\includegraphics[height=5cm,width=6.2cm]{Figure_1.png}
\label{Fig1}
\end{figure}
\end{proof}
\subsection*{Problem \uppercase\expandafter{\romannumeral6}}
\begin{proof}[\textbf{Solution.}]
By setting $f = t-x$, $g = (t-x)_+$ in Leibniz formula , we have
\begin{equation}
\begin{aligned}
    &[t_{i-1},t_i,t_{i+1}](t-x)^2_+ = (t_{i-1} - x)[t_{i-1},t_i,t_{i+1}](t-x)_+ +  [t_i,t_{i+1}](t-x)_+, \\
    &[t_{i},t_{i+1},t_{i+2}](t-x)^2_+ = (t_{i} - x)[t_{i},t_{i+1},t_{i+2}](t-x)_+ +  [t_{i+1},t_{i+2}](t-x)_+.
\end{aligned}
\end{equation}
Therefore, together with \textbf{Theorem 2.17} and \textbf{Example 3.31},
\begin{equation}
\begin{aligned}
    &(t_{i+2}-t_{i-1})[t_{i-1},t_i,t_{i+1},t_{i+2}](t-x)^2_+ \\
    &= [t_i,t_{i+1},t_{i+2}](t-x)^2_+ - [t_{i-1},t_i,t_{i+1}](t-x)^2_+\\
    &= (t_{i} - x)[t_{i},t_{i+1},t_{i+2}](t-x)_+ +  [t_{i+1},t_{i+2}](t-x)_+ \\
    &- (t_{i-1} - x)[t_{i-1},t_i,t_{i+1}](t-x)_+ -  [t_i,t_{i+1}](t-x)_+ \\
    &= (t_{i} - x + t_{i+2}-t_i)[t_{i},t_{i+1},t_{i+2}](t-x)_+  - (t_{i-1} - x)[t_{i-1},t_i,t_{i+1}](t-x)_+ \\
    &= (t_{i+2} - x)[t_{i},t_{i+1},t_{i+2}](t-x)_+  + (x-t_{i-1})[t_{i-1},t_i,t_{i+1}](t-x)_+ \\
    &= (t_{i+2} - x)[\frac{(t_{i+2}-x)_+-(t_{i+1}-x)_+}{(t_{i+2}-t_{i+1})(t_{i+2}-t_{i})} - \frac{(t_{i+1}-x)_+-(t_{i}-x)_+}{(t_{i+1}-t_{i})(t_{i+2}-t_{i})}] \\
    &+ (x-t_{i-1})[\frac{(t_{i+1}-x)_+-(t_{i}-x)_+}{(t_{i+1}-t_{i})(t_{i+1}-t_{i-1})} - \frac{(t_{i}-x)_+-(t_{i-1}-x)_+}{(t_{i}-t_{i-1})(t_{i+1}-t_{i-1})}].
\end{aligned}
\end{equation}
From the "simplified" formula above, it's not difficult to use the definition of truncated power function and know that 
\begin{align*}
\begin{split}
&(t_{i+2}-t_{i-1})[t_{i-1},t_i,t_{i+1},t_{i+2}](t-x)^2_+ \\
&=\left \{
\begin{array}{ll}
    (t_{i+2} - x)\cdot0 + (x-t_{i-1})[\frac{1}{t_{i+1}-t_{i-1}}-\frac{(t_{i}-x)}{(t_{i}-t_{i-1})(t_{i+1}-t_{i-1})}] = \frac{(x-t_{i-1})^2}{(t_{i+1}-t_{i-1})(t_{i}-t_{i-1})},                    & x \in (t_{i-1},t_i]\\
    \frac{(t_{i+2}-x)}{t_{i+2}-t_{i}}-\frac{(t_{i+1}-x)(t_{i+2}-x)}{(t_{i+1}-t_{i})(t_{i+2}-t_{i})} +\frac{(x-t_{i-1})(t_{i+1}-x)}{(t_{i+1}-t_{i-1})(t_{i+1}-t_{i})}= \frac{(x-t_{i-1})(t_{i+1}-x)}{(t_{i+1}-t_{i-1})(t_{i+1}-t_{i})} +\frac{(t_{i+2}-x)(x-t_i)}{(t_{i+2}-t_{i})(t_{i+1}-t_{i})},                   & x \in (t_{i},t_{i+1}]\\
    (t_{i+2}-x)\frac{t_{i+2}-x}{(t_{i+2}-t_{i})(t_{i+2}-t_{i+1})}, & x \in (t_{i+1},t_{i+2}]\\
    0, &otherwise
\end{array}
\right.
\end{split}
\end{align*}
which is algebraically identical to $B^2_i$.
\end{proof}
\subsection*{Problem \uppercase\expandafter{\romannumeral7}}
\begin{proof}[\textbf{Solution.}]
For any fixed $n$, from \textbf{Theorem 3.34}, $\frac{\mathrm{d}}{\mathrm{d} x}B^{n+1}_i(x)$ can be expressed as
\begin{equation}
    \frac{\mathrm{d}}{\mathrm{d} x}B^{n+1}_i(x) = \frac{n}{t_{i+n}-t_{i-1}}B^{n}_i(x)-\frac{n}{t_{i+n+1}-t_{i}}B^{n}_{i+1}(x).
\end{equation}
Integrate the left and right hand sides of the equation from $t_{i-1}$ to $t_{i+n+1}$ and we have
\begin{equation}
    \frac{1}{n}\int_{t_{i-1}}^{t_{i+n+1}} \frac{\mathrm{d}}{\mathrm{d} x}B^{n+1}_i(x)\, dx = \frac{1}{t_{i+n}-t_{i-1}}\int_{t_{i-1}}^{t_{i+n+1}} B^{n}_i(x) \, dx - \frac{1}{t_{i+n+1}-t_{i}} \int_{t_{i-1}}^{t_{i+n+1}} B^{n}_{i+1}(x) \, dx.
\end{equation}
Since $\frac{\mathrm{d}}{\mathrm{d} x}B^{n+1}_i(x)$ has primitive function $B^{n+1}_i(x) + C$ where $C$ is an arbitrary constant, and the support of $B^{n+1}_i(x) + C$ is $[t_{i-1},t_{i+n+1}]$, the LHS of the equation is equal to $\frac{1}{n}[B^{n+1}_i(t_{i+n+1}) - B^{n+1}_i(t_{i-1})]=0$.

As for the RHS of the equation, \textbf{Lemma 3.27} told that the support of $B^{n}_i(x)$ is $[t_{i-1},t_{i+n}]$, and the support of $B^{n}_{i+1}(x)$ is $[t_{i},t_{i+n+1}]$. Therefore the equation is finally translated to
\begin{equation}
    \frac{1}{t_{i+n}-t_{i-1}}\int_{t_{i-1}}^{t_{i+n}} B^{n}_i(x) \, dx = \frac{1}{t_{i+n+1}-t_{i}} \int_{t_{i}}^{t_{i+n+1}} B^{n}_{i+1}(x) \, dx,
\end{equation}
and that shows the scaled integral of $B^{n}_i(x)$ is the same for any adjacent $i$, which implies the independence of index $i$ for any knots' form by a simple recursion. 
\end{proof}
\subsection*{Problem \uppercase\expandafter{\romannumeral8}}
\subsubsection*{(a)}
\begin{proof}[\textbf{Solution.}]
We now need to prove
\begin{equation}
    \tau_2(x_i,x_{i+1},x_{i+2}) = [x_i,x_{i+1},x_{i+2}]x^4
\end{equation}
The relative table of divided difference of $[x_i,x_{i+1},x_{i+2}]x^4$ is shown below.
\begin{table}[H]
\renewcommand{\arraystretch}{1.2}
 \centering
 \setlength{\tabcolsep}{0.3cm}{
\begin{tabular}{c|ccc}
    $x_i$ & $x^4_i$  \\
    $x_{i+1}$ & $x^4_{i+1}$ & $K_1:=(x^2_{i+1}+x^2_{i})(x_{i+1}+x_{i})$ \\
    $x_{i+2}$ & $x^4_{i+2}$ & $K_2:=(x^2_{i+2}+x^2_{i+1})(x_{i+2}+x_{i+1})$ & $\frac{K_2-K_1}{x_{i+2}-x_i}$ \\
\end{tabular}}
\end{table}
Therefore, 
\begin{equation}
\begin{aligned}
        [x_i,x_{i+1},x_{i+2}]x^4 &= \frac{(x^2_{i+2}+x^2_{i+1})(x_{i+2}+x_{i+1})-(x^2_{i+1}+x^2_{i})(x_{i+1}+x_{i})}{x_{i+2}-x_i} \\
        &=\frac{(x_{i+2}-x_i)(x^2_{i+2}+x_ix_{i+2}+x^2_i)+x^2_{i+1}(x_{i+2}-x_i)+x_{i+1}(x_{i+2}+x_i)(x_{i+2}-x_i)}{x_{i+2}-x_i} \\
        &= x^2_{i+2}+x_ix_{i+2}+x^2_i + x^2_{i+1} + x_{i+1}(x_{i+2}+x_i) \\
        & = \tau_2(x_i,x_{i+1},x_{i+2}).
\end{aligned}
\end{equation}
\end{proof}
\subsubsection*{(b)}
\begin{proof}[\textbf{Solution.}]
Exactly the same as the one in \textbf{Theorem 3.46}. 

By \textbf{Lemma 3.45}, we have
\begin{equation}
\begin{aligned}
    &(x_{n+1}-x_1)\tau_k(x_1,\dots,x_n,x_{n+1}) \\
    &= \tau_{k+1}(x_1,\dots,x_n,x_{n+1}) - \tau_{k+1}(x_1,\dots,x_n) - x_1\tau_k(x_1,\dots,x_n,x_{n+1}) \\
    &= \tau_{k+1}(x_2,\dots,x_n,x_{n+1}) + x_1\tau_k(x_1,\dots,x_n,x_{n+1})  - \tau_{k+1}(x_1,\dots,x_n) - x_1\tau_k(x_1,\dots,x_n,x_{n+1}) \\
    &= \tau_{k+1}(x_2,\dots,x_n,x_{n+1}) - \tau_{k+1}(x_1,\dots,x_n).
\end{aligned}
\end{equation}
The rest of the proof is an induction on $n$. For $n=0$, it reduces to
\begin{equation}
    \tau_m(x_i) = [x_i]x^m,
\end{equation}
which is trivially true. Now suppose the condition holds for a non-negative integer $n<m$. Then (26) and the induction hypothesis yield
\begin{equation}
\begin{aligned}
    &\tau_{m-n-1}(x_{i},\dots,x_{i+n+1}) \\
    &= \frac{\tau_{m-n}(x_{i+1},\dots,x_{i+n+1})-\tau_{m-n}(x_{i},\dots,x_{i+n})}{x_{i+n+1}-x_i} \\
    &= \frac{[x_{i+1},\dots,x_{i+n+1}]x^m-[x_{i},\dots,x_{i+n}]x^m}{x_{i+n+1}-x_i} \\
    &= [x_{i},\dots,x_{i+n+1}]x^m,
\end{aligned}
\end{equation}
which completes the proof.
\end{proof}
\end{sloppypar}
\end{document}
